#ifdef OSGI_USE_15S_HEADER
#include "../interface/InterfaceDef.h"
#include "osgi-core/osgi-predefined.h"
#else // OSGI_USE_15S_HEADER
#ifndef OSGI_CORE_IBUNDLEEVENT_H__
#define OSGI_CORE_IBUNDLEEVENT_H__

#include "osgi-predefined.h"
#include"IEvent.h"

#define BUNDLE_LOADED_EVENT			1
#define BUNDLE_UNLOAD_EVENT			2
#define BUNDLE_INSTALLED_EVENT		3
#define BUNDLE_RESOLVED_EVENT		4
#define BUNDLE_RESOLVING_EVENT      5
#define BUNDLE_ACTIVATED_EVENT		6
#define BUNDLE_STARTED_EVENT		7
#define BUNDLE_STARTING_EVENT		8
#define BUNDLE_STOPPED_EVENT		9
#define BUNDLE_STOPPING_EVENT		10
#define BUNDLE_UNINSTALLED_EVENT	11
#define BUNDLE_UNINSTALLING_EVENT   12
//#define BUNDLE_UPDATED_EVENT		13

OSGI_NAMESPACE_BEGIN

OSGI_INTERFACE IBundleEvent : public IEvent
{
	virtual ~IBundleEvent() {}

	virtual const char* OSGI_API EventDesp() = 0;
	virtual const char* OSGI_API BundleName() = 0;
	virtual IDictionary* OSGI_API BundleAttr() = 0;
};

OSGI_INTERFACE IBundleEventListener
{
	virtual ~IBundleEventListener() {}

	virtual int OSGI_API OnBundleEvent(
		IBundleEvent* event) = 0;
};

OSGI_NAMESPACE_END
#endif // OSGI_CORE_IBUNDLEEVENT_H__
#endif // OSGI_USE_15S_HEADER